package com.example.sxt_practise.GOF23.proxypattern.dynamicproxy;

import java.lang.reflect.InvocationHandler;
import java.lang.reflect.Method;

/**
 * @author gaofeng
 * @date 2022年05月22日 10:57
 */
public class StarHandler implements InvocationHandler {

    private Star realStar ;

    public StarHandler(Star realStar) {
        this.realStar = realStar;
    }

    @Override
    public Object invoke(Object proxy, Method method, Object[] args) throws Throwable {
        method.invoke(realStar, args) ;
        return null;
    }
}
